<?
    class Principio_Model_Type
    {
        private $id;
        private $type;
        private $caption;
        private $exts;
        private $model_firmware;

        public function __construct(&$values = null)
        {
            if (is_null($values))
            {
                $this->id = -1;
                $this->caption = "";
                $this->model_firmware = Principio_Model_FirmwareMapper::get(-1);
                $this->exts = 0;
            }
            else
            {
                $this->id = (isset($values['id']) ? intval($values['id']) : -1);
                $this->caption = $values['caption'];
                $this->type = $values['type'];
                $this->exts = intval($values['exts']);
                $this->model_firmware = Principio_Model_FirmwareMapper::get(intval($values['firmware_id']));
            };
        }


        public function getID()
        {
            return $this->id;
        }


        public function setID($id)
        {
            $this->id = intval($id);
            return $this;
        }


        public function getType()
        {
            return $this->type;
        }


        public function setType($type)
        {
            $this->type = $type;
            return $this;
        }


        public function getCaption()
        {
            return $this->caption;
        }


        public function setCaption($caption)
        {
            $this->caption = $caption;
            return $this;
        }


        public function getModelFirmware()
        {
            return $this->model_firmware;
        }


        public function setModelFirmware(Principio_Model_Firmware $model_firmware)
        {
            $this->model_firmware = $model_firmware;
            return $this;
        }


        public function getExts()
        {
            return $this->exts;
        }


        public function setExts($exts)
        {
            $this->exts = intval($exts);
            return $this;
        }
    }
?>